<?php

namespace App\Models;


use App\Service\Base\Model;

class SiteIp extends Model
{

    // 用户管理
    protected $table = 'site_ip';

    // 缓存字段，用于搜索绑定的字段
    protected $cacheFields = ['id', 'ip'];


    // 定义验证操作
    public function rules()
    {

        $add = [
        ];

        $edit = [
        ];

        $info = [
        ];


        $rule = [
            'ip'   => 'required',
            'city' => 'required',
            'prov' => 'required',
        ];


        $msg = [
            'id'   => '编号',
            'ip'   => 'ip地址',
            'city' => '城市',
            'prov' => '省份',
        ];

        return ['rule' => $rule, 'msg' => $msg, 'add' => $add];
    }
}
